<app-table-detail [tableDetailModel]="tableDetailModel"></app-table-detail>
<!--  修改信息-->
<nz-modal [(nzVisible)]="isVisible" nzTitle="【修改资料】"
          (nzOnCancel)="isVisible = false" nzOkText="提交"
          (nzOnOk)="submit(formInfoModel.formInfo)"
          [nzOkDisabled]="formInfoModel.getDisabled()||appService.getLoading()">
  <app-form-info [formInfoModel]="formInfoModel"></app-form-info>
</nz-modal>
<!--  修改邮箱/手机号-->
<nz-modal [(nzVisible)]="editBasicUser.isVisible" [nzTitle]="captchaInfo.type === 'email' ? '【修改邮箱】' : '【修改手机号】'"
          (nzOnCancel)="editBasicUser.isVisible=false"
          [nzOkDisabled]="!captchaInfo.account||!captchaInfo.captcha||appService.getLoading()"
          nzOkText="提交"
          (nzOnOk)="confirmOk()">
  <div class="edit-form">
    <nz-form-item>
      <nz-form-label [nzSm]="6" [nzXs]="24" nzRequired
      >{{captchaInfo.type === 'email' ? '新邮箱' : '新手机号' }}</nz-form-label>
      <nz-form-control [nzSm]="14" [nzXs]="24">
        <input nz-input [(ngModel)]="captchaInfo.account"/>
      </nz-form-control>
    </nz-form-item>
    <nz-form-item>
      <nz-form-label [nzSm]="6" [nzXs]="24" nzRequired>验证码</nz-form-label>
      <nz-form-control [nzSm]="14" [nzXs]="24">
        <div nz-row [nzGutter]="8">
          <div nz-col [nzSpan]="12">
            <input nz-input [(ngModel)]="captchaInfo.captcha"/>
          </div>
          <div nz-col [nzSpan]="12">
            <button nz-button
                    (click)="sendCaptcha($event,captchaInfo.account,captchaInfo.type === 'phone' ? 'update_phone' : 'update_email')">
              {{captchaInfo.buttonName}}
            </button>
          </div>
        </div>
      </nz-form-control>
    </nz-form-item>
  </div>
</nz-modal>

<!--  注销账号-->
<nz-modal [(nzVisible)]="logOffBasic.isVisible" [nzTitle]="'【注销账号】'"
          (nzOnCancel)="logOffBasic.isVisible=false"
          [nzOkDisabled]="!captchaInfo.captcha||appService.getLoading()"
          nzOkText="注销"
          (nzOnOk)="logOffConfirmOk()">
  <div class="edit-form">
    <nz-form-item>
      <nz-form-label [nzSm]="6" [nzXs]="24" nzRequired>{{logOffBasic.name}}</nz-form-label>
      <nz-form-control [nzSm]="14" [nzXs]="24">
        <div nz-row [nzGutter]="8">
          <div nz-col [nzSpan]="12">
            <input nz-input [(ngModel)]="captchaInfo.captcha"/>
          </div>
          <div nz-col [nzSpan]="12">
            <button nz-button (click)="sendCaptcha($event, captchaInfo.account,'unsubscribe')">
              {{captchaInfo.buttonName}}
            </button>
          </div>
        </div>
      </nz-form-control>
    </nz-form-item>
  </div>
</nz-modal>
